import {debounce} from "./utils";
import BackTop from "components/content/backTop/BackTop";
export const itemListtenerMixin = {
    mounted() {
        //监听itemimage加载完成
        const refresh = debounce(this.$refs.scroll.refresh);

        this.itemImglistenr = () => {
            //console.log("----");
            refresh()
        }
        this.$bus.$on('itemImageload', this.itemImglistenr)
    }
}
export const backTopMixin = {
    components: {
        BackTop
    },
    data() {
        return {
            isShowBackTop: false,
        }
    },
    methods: {
        backClick() {
            this.$refs.scroll.scrollTo(0, 0)
        },
    }
}